import Vue from 'vue'
import Router from 'vue-router'
import home from '@/components/home'
import member from '@/components/member'
import search from '@/components/search'
import shopcar from '@/components/shopcar'
import newList from '@/components/menu/newList'
import newInfo from '@/components/menuInfo/newInfo'
import photo from '@/components/menu/photo'
import photoInfo from '@/components/menuInfo/photoInfo'
import goodsList from '@/components/menu/goodsList'
import goodsInfo from '@/components/menuInfo/goodsInfo'



Vue.use(Router)

export default new Router({
  routes: [{
      path: '/',
      redirect: 'home'
    },
    {
      path: '/home',
      component: home
    },
    {
      path: '/member',
      component: member
    },
    {
      path: '/search',
      component: search
    },
    {
      path: '/shopcar',
      component: shopcar
    },
    {
      path: '/home/newList',
      component: newList
    },
    {
      path:'/home/newInfo/:id',
      component:newInfo
    },
    {
      path: '/home/photo/:id',
      component: photo
    },
    {
      path: '/home/photoInfo/:id',
      component: photoInfo
    },
    {
      path:'/home/goodsList',
      component:goodsList
    },
    {
      path:'/home/goodsInfo/:id',
      component:goodsInfo
    }
  ],
  linkActiveClass: 'mui-active'
})
